<!DOCTYPE html>
{% load static %}
<html lang="zh-cn">
<head>
    <script type='text/javascript' src="static/fybjs/htmlAceControlShow.js"></script>
    <script>
        headLoadFile('新一代工业软件应用商店');
    </script>
    <!--付颖斌的js文件-->
    <script type='text/javascript' src="static/fybjs/httpDataTransFyb.js"></script>
    <script>
        $.ajaxSetup({data:{csrfmiddlewaretoken:'{{ csrf_token }}'}})
    </script>

</head>
<body class="no-skin">
<!--导航栏index-->
<script>
    //权限控制
    jumpURL=getAuthURL(window.location.href);
    if(jumpURL!=window.location.href){window.location.href=jumpURL;}else{};
    //加载内容
    shortCutText=['平台主页','数据聚合','情景推荐'];
    shortCutText=[];
    shortCutLiColor=['grey','purple','green'];
    shortCutHref=['#','#','https://www.baidu.com'];
    shortCutSrc=['static/ace/assets/images/avatars/platform.png','static/ace/assets/images/avatars/process.png','static/ace/assets/images/avatars/support.png'];
    navBarShowAceIndexFyb("","新一代工业软件应用商店","工业软件库","欢迎光临",shortCutText, shortCutLiColor, shortCutHref, shortCutSrc);

    var flowID='1';//流程id
</script>

<div class="main-container ace-save-state" id="main-container">
    <!--嵌入侧边栏-->
    <div class="sidebar responsive ace-save-state" id="sidebar">
        <!-- 功能按钮区域 -->
        <script>
            buttonClass=['btn btn-success','btn btn-info','btn btn-warning','btn btn-danger'];
            dataToggle=['tab','modal','modal','modal'];
            dataTarget=['#projectManagementDiv','#newProjectModal','#helpModal','#dangerModal'];
            buttonID=['','','',''];
            iClass=['ace-icon fa fa-cog','ace-icon fa fa-table','ace-icon fa fa-users','ace-icon fa fa-bell-o'];
            //leftTopNavBarControlButtonAceFyb(buttonClass, dataToggle, dataTarget, buttonID, iClass);
        </script>
        <!-- 侧边栏 -->
        <script>
            menuList=JSON.parse(getUserMenuList());
            menuActiveID=getNavBarMenuActiveId(getHtmlUrlAlone(location.href),menuList[0]['cotentDataHref'], menuList[0]['cotentMenuID'],"@");
            leftContentNavBarAceFyb(menuList[0]['titleData'], menuList[0]['titleiClass'], menuList[0]['titleHref'], menuList[0]['cotentData'], menuList[0]['contentiClass'], menuList[0]['cotentDataHref'],menuActiveID);
        </script>


    </div>
    <div class="main-content">
        <div class="main-content-inner">
            <!--嵌入面包屑-->
            <script>
                var titleBreadData=['新一代工业软件平台','#'];
                var searchString=['noshow',''];
                var otherBreadData=new Array();
                otherBreadData[0]=['系统管理','#'];
                otherBreadData[1]=['角色列表','#'];
                testID=breadCrumbsAceFyb(titleBreadData,otherBreadData, searchString);
            </script>

            <div class="page-content">
                <div class="row">
                    <div class="col-sm-6">
                        <div class="tabbable">
                            <ul class="nav nav-tabs" id="myTab">
                                <script type='text/javascript'>
                                    subContentPageAceFyb('URL管理',true,'#');
                                </script>
                            </ul>
                            <div class="tab-content" id="pageContent">
                                <!--开始写入正文-->

                                <script>//获取系统的所有url信息
                                    var transUrl='dataTransferFybAdmin';//传输数据的URL
                                    var transType='POST';
                                    var transAsync=false;//表明同步数据传输
                                    var columnName=['id', 'role_name', 'role_str', ];
                                    var transData={
                                        table:dbTableHead + 'role_infor',
                                        sqlType:'query',
                                        column:matrixTransStringForSqlColumn(columnName),
                                        userAccount:userAccount,
                                        enterAccount:enterAccount,
                                        restraint:'',
                                    };
                                    queryData=dataTransferFyb(transUrl,transType,transAsync,transData);

                                    var tableID='fybtable';
                                    var tableTitleMatrix=['id','序号','角色名称','角色字符串', '角色目录编辑', '编辑',];
                                    var tableTitleClass=['','','','','','',];
                                    var tableTitleStyle=['display:none','','','','','',];
                                    var lastControlMatrix=['modify'];
                                    var tableDataMatrix=new Array();
                                    var tableOnClickMatrix=new Array();
                                    for(var i=0;i<queryData.length;i++)
                                    {
                                        tableDataMatrix[i]=[queryData[i]['id'], i+1,queryData[i]['role_name'],queryData[i]['role_str'], '菜单编辑',];
                                        tableOnClickMatrix[i]=['#','#','','', 'roleMenuListEdit?roleStr='+queryData[i]['role_str'],''];
                                    }
                                    //tableAddControlAndOnclickAceFyb(tableID, tableTitleMatrix,tableTitleClass,tableTitleStyle, tableDataMatrix, tableOnClickMatrix, lastControlMatrix);
                                    tableAddControlAndUrlShowAceFyb(tableID, tableTitleMatrix,tableTitleClass,tableTitleStyle, tableDataMatrix, tableOnClickMatrix, lastControlMatrix);
                                    //tableAddControlShowAceFyb(tableID, tableTitleMatrix,tableTitleClass,tableTitleStyle, tableDataMatrix, lastControlMatrix);
                                    //tableSimpleShowAceFyb(tableID, tableTitleMatrix,tableTitleClass,tableDataMatrix);
                                </script>

                                <script>
                                    //roleMenuListModelShow();
                                    //编辑数据按钮点击后事件
                                    var tableFyb=document.getElementById("fybtable");//获取表格id为'fybtable'的表格
                                    var tds = tableFyb.getElementsByTagName("button");//获取表格中，tagName为button的一行元素

                                    for(var i=0,j=tds.length;i<j;i++) {
                                        tds[i].onclick = function () {
                                            //alert(this.value);
                                            var clickValueMatrix=this.value.split('|');//分割文本
                                            if(clickValueMatrix.length==2)
                                            {//确定格式符合标准
                                                if(clickValueMatrix[0]=='warning')//测试链接
                                                {
                                                }else if(clickValueMatrix[0]=='modify')//修改
                                                {
                                                    window.location.href='roleListModify?id='+clickValueMatrix[1];
                                                    //window.location.href='staffModify.html?id='+clickValueMatrix[1];
                                                }
                                            }

                                        }
                                    }
                                </script>

                                <!--结束写入正文-->
                                <!--测试-->

                                <!--测试结束-->
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <!--footer,显示版权信息-->
    <script>
        copyRightAceFyb('长安大学汽车学院物流工程系', 'https://qiche.chd.edu.cn/2020/1208/c8529a173474/page.htm/', '2021');
    </script>

</div>

</body>
</html>